package de.koller.renderEngine;

import de.koller.oceanFramework.gl.util.InputGL;
import de.koller.oceanFramework.tree.Child;
import de.koller.renderEngine.render.RERendering;
import de.koller.oceanFramework.tree.Sea3X;
import org.lwjgl.input.Keyboard;

public class RERoot extends Sea3X {

	@Child public final InputGL input = new InputGL();
	@Child public final RERendering rendering = new RERendering();

	@Override
	protected void update( int elapsedTime ) {
		super.update( elapsedTime );
		
		if( input.isKeyPressed( Keyboard.KEY_1 ) )
			rendering.renderSlow();
	}
	
	@Override
	protected void render( int elapsedTime ) {
		super.render( elapsedTime );
		
		rendering.renderFast();
	}
	
}
